<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css" integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu" crossorigin="anonymous">
    <title>Document</title>
    <style>
        th,tr{
            text-align: center;

        }
    </style>
</head>
<body>
<a href="#"><button class="layui-btn layui-btn-normal">添加</button></a>
<a href="#"><button class="layui-btn layui-btn-warm">修改</button></a>
<a href="#"><button class="layui-btn layui-btn-danger">删除</button></a>
<table class="layui-table">
    <colgroup>
        <col width="50">
        <col width="80">
        <col>
    </colgroup>

    <thead>
    <tr>
        <th class="layui-bg-green">主键id</th>
        <th class="layui-bg-green">商品名称</th>
        <th class="layui-bg-green">买家信息</th>
        <th class="layui-bg-green">订单号</th>
        <th class="layui-bg-green">送货方式</th>
        <th class="layui-bg-green">订单状态</th>
        <th class="layui-bg-green">地址</th>
        <th class="layui-bg-green">支付方式</th>
        <th class="layui-bg-green">支付人身份</th>
        <th class="layui-bg-green">支付人名称</th>
        <th class="layui-bg-green">订单备注</th>
        <th class="layui-bg-green">商品价格</th>
        <th class="layui-bg-green">商品名称</th>
    </tr>
    </thead>
    <tbody>
    {foreach $arr as $k=>$s}
    <tr>
        <td>{$s.id}</td>
        <td>{$s.goods_name}</td>
        {foreach $data as $k=>$v}
        <td>
            昵称 {$v.nickname}
            <br>
            姓名 {$v.username}
            <br>
            电话  {$v.mobile}
            <br>
            地址   {$s.details_address}
        </td>
        {/foreach}
        <td>{$s.order_id}</td>
        <td>{$s.delivery_type==0?'自提':'送货上门'}</td>
        <td>{$s.order_status==3?'已完成':'未完成'}</td>
        <td>{$s.details_address}</td>
        <td>{$s.pay_type==1?'微信支付':'支付宝支付'}</td>
        <td>{$s.pay_identity}</td>
        <td>{$s.pay_name}</td>
        <td>{$s.order_remarks}</td>
        <td>{$s.goods_price}</td>
        <td>{$s.goods_name}</td>
    </tr>
    </tbody>
    {/foreach}
</table>
{$arr|raw}
</body>
</html>

